<!DOCTYPE html>
<html>
    <head>
        <title>#{get 'title' /}</title>
        <meta http-equiv="Content-Type" content="text/html; charset=${_response_encoding}">
        <link rel="stylesheet" type="text/css" media="screen" href="@{'/public/stylesheets/main.css'}">
        #{get 'moreStyles' /}
        <link rel="shortcut icon" type="image/png" href="@{'/public/images/favicon.png'}">
        <script src="@{'/public/javascripts/jquery-1.3.2.min.js'}" type="text/javascript" charset="${_response_encoding}"></script>
        <script src="@{'/public/javascripts/sessvars.js'}" type="text/javascript" charset="${_response_encoding}"></script>
        #{get 'moreScripts' /}
    </head>
    <body>
        <div id="header">
            <h1>登陆 | 注册 | 搜索 | 编辑 | 退出 | 修改密码</h1>
            #{if user?.id}
                <div id="options">
                                              登陆用户 ${user.username}
                    |
                    <a href="@{Hotels.index()}">搜索</a>
                    |
                    <a href="@{Hotels.settings()}">修改密码</a>
                    |
                    <a href="@{Application.logout()}">退出</a>
                </div>
            #{/if}
        </div>
        
        <div id="content">
            #{if flash.error}
                <p class="fError">
                    <strong>${flash.error}</strong>
                </p>
            #{/if}
            #{if flash.success}
                <p class="fSuccess">
                    <strong>${flash.success}</strong>
                </p>
            #{/if}
            
            #{doLayout /}
        </div>
    </body>
</html>